package io.kiki.stack.netty.config;

import io.kiki.stack.netty.config.configs.ConfigContainer;
import io.kiki.stack.netty.config.switches.GlobalSwitch;


public interface Configurable {


    @Deprecated
    ConfigContainer conf();


    @Deprecated
    GlobalSwitch switches();

    /**
     * Initialize netty write buffer water mark for remoting instance.
     * <p>
     * Notice: This api should be called before init remoting instance.
     * <p>
     * deprecated, use option() instead:
     * instance#option(Option.NETTY_BUFFER_LOW_WATER_MARK, low);
     * instance#option(Option.NETTY_BUFFER_HIGH_WATER_MARK, high);
     *
     * @param low  [0, high]
     * @param high [high, Integer.MAX_VALUE)
     */
    @Deprecated
    void initWriteBufferWaterMark(int low, int high);

    /**
     * get the low water mark for netty write buffer
     * deprecated, use instance#option(ClientOption.NETTY_BUFFER_LOW_WATER_MARK) instead
     *
     * @return low watermark
     */
    @Deprecated
    int netty_buffer_low_watermark();

    /**
     * get the high water mark for netty write buffer
     * deprecated, use instance#option(ClientOption.NETTY_BUFFER_HIGH_WATER_MARK) instead
     *
     * @return high watermark
     */
    @Deprecated
    int netty_buffer_high_watermark();
}